package com.bionic.ce.connections;
import com.bionic.ce.dao.IBankaccDAO;
import com.bionic.ce.dao.ICurrencyDAO;
import com.bionic.ce.dao.IOfficialbankrateDAO;
import com.bionic.ce.dao.IQueryDAO;
import com.bionic.ce.dao.ISystemaccDAO;
import com.bionic.ce.dao.IUserDAO;

public abstract class DAOFactory {

    public static final int MYSQL = 1;
    // here could be assigned other DB types

    public abstract IBankaccDAO getBankaccDAO();

    public abstract ICurrencyDAO getCurrencyDAO();

    public abstract IOfficialbankrateDAO getOfficialbankrateDAO();

    public abstract IQueryDAO getQueryDAO();

    public abstract ISystemaccDAO getSystemaccDAO();

    public abstract IUserDAO getUserDAO();

    public static DAOFactory getDAOFactory(int whichFactory) {
        switch (whichFactory) {
            case MYSQL:
                return new MySQLDAOFactory();
            // here could be assigned other DB types
            default:
                return null;
        }
    }
}
